<%@ page pageEncoding="utf-8"
    import="java.util.*, service1.*"%><%
        String q = "macbook";
        Map item = GetSearchResults.getItemByRandom(q);
%>
function showShopGallery() {
  var shopg_link = 'http://itempage.auction.co.kr/detailview.aspx?itemno=<%= item.get("itemId") %>';
  var shopg_image = 'http://image.auction.co.kr/itemimage<%= item.get("image") %>';
  var shopg_name = '<%= item.get("name") %>';
  var shopg_price = '<%= item.get("buyItNowPrice") %>';
  var htmlCode = 
'<link rel="stylesheet" type="text/css" href="http://www.okjsp.pe.kr/mashup/style.css" />\
\
<table class="shopg"><tr>\
<td rowspan="2"><a \
href="'+shopg_link+'"><img \
src="'+shopg_image+'"></a></td>\
<td><div class="shopg_name">'+shopg_name+'</div></td>\
</tr>\
<tr>\
<td>'+shopg_price+'</td>\
</tr></table>\
';

  document.write(htmlCode);
}

showShopGallery();
